package com.feibiao.computer;

public class ComputeFactory {

    public static Compute getOperator(String operator){

        Compute com = null;
        switch (operator){
            case "+" :com = new ADD();break;
            case "-" :com = new Sub();break;
            case "*" :com = new Mul();break;
            case "/" :com = new Div();break;
            case "^" :com = new Involution();break;
            case "!":com = new Factorial();break;
        }
        return com;
    }
}
